<extend name="Layout:layout_grid" />
<block name="body_main">
    <div class="grid-container grid-parent page-header">
        <div class="grid-60 mobile-grid-100 grid-parent">
            <a href="{:AddonU('document_edit','category_id='.$search['category_id'])}" class="xsui-btn ui-state-default lnk-add"><i class="fa fa-plus"></i>新增</a>
            <a href="{:AddonU('document_export')}" class="xsui-btn ui-state-default"><i class="fa fa-save"></i>导出</a>
            <a href="{:AddonU('config_export','id=varkey')}" class="xsui-btn ui-state-default lnk-remove"><i class="fa fa-remove"></i>批量删除</a>
            <a href="{:AddonU('Dig/record_list')}" class="xsui-btn ui-state-default lnk-tab"><i class="fa fa-save"></i>数据采集</a>
        </div>
        <div class="grid-40 mobile-grid-100 grid-parent xsui-text-right">
            <a href="#" class="xsui-btn ui-state-default lnk-refresh"><i class="fa fa-refresh"></i>刷新</a>
            <span class="xsui-input-group"><form method="get"><input type="text" name="search_key" value="{$search.search_key}" placeholder="标题" /><button type="submit" class="ui-state-default"><i class="fa fa-search"></i>搜索</button><button id="btn-search-dialog" class="ui-state-default xsui-icon-only" title="高级搜索"><i class="fa fa-gear"></i></button></form></span>
        </div>
        <div id="search-dialog" class="xsui-hidden">
            <form method="get" class="xsui-form">
                <div class="xsui-form-field">
                    <label>标题：</label><input type="text" name="title" value="{$search.title}" />
                </div>
                <div class="xsui-form-field">
                    <label>栏目：</label><select name="category_id" data-url="{:AddonU('Channels/get_channel_tree_json','type_id=2')}" data-value="{$search.category_id}"></select>
                </div>
                <button type="submit" class="xsui-hidden">提交</button>
            </form>
        </div>
    </div>
    <div id="grid-container">
        {$content}
    </div>
</block>
<block name="body_foot_script">    
    <script type="text/javascript">
        $(function () {
            // 网页页面视图初始化 2015-10-17 SoChishun Added.
            var gridPage = GridPage.newInstance();
            gridPage.ui_init();
            ajax_combobox({selector: 'select[name="category_id"]', def_option: '请选择类别'});
        })
    </script>
</block>